var express = require('express');
var router = express.Router();

var open = {
    setToken : require('./setToken'),
    getToken : require('./getToken'),
    upToken : require('./upToken'),
    deleteToken : require('./deleteToken'),
    getRegion : require('./getRegion'),
    setRegion : require('./setRegion'),
    qrcode : require('./qrcode')
};

/* GET home page. */
router.get('/getRegion', open.getRegion);
router.get('/setRegion', open.setRegion.GET);

router.post('/qrcode', open.qrcode);
router.post('/setToken', open.setToken);
router.post('/getToken', open.getToken);
router.post('/upToken', open.upToken);
router.post('/deleteToken', open.deleteToken);
router.post('/getRegion', open.getRegion);
router.post('/setRegion', open.setRegion.POST);

module.exports = router;
